package com.baidu.mapper;

import com.baidu.pojo.Role;
import com.github.pagehelper.Page;

import java.util.List;
import java.util.Map;
import java.util.Set;

public interface RoleMapper {
	Set<Role> findRoleByUid(Integer userid);

	/**
	 * 查询所有角色，展示在前端页面
	 */

	List<Role> findAll();

	public void addRole(Role role);

	public void setRoleAndPermission(Map map);

	public Role findRoleById(Integer id);

	public Page<Role> findPageByQueryString(String queryString);

	public void deleteRoleAndPermission(Integer roleid);

	public void editRole(Role role);

	public void deleteRoleById(Integer id);

	public Integer findRoleAndPermission(Integer roleid);
}
